package com.gdut.demo.service;

import com.gdut.demo.dao.EcgDao;
import com.gdut.demo.entity.Ecg;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
public class EcgServiceImpl implements EcgService {

    @Autowired
    private EcgDao ecgDao;

    @Override
    public Ecg getOne(Integer id) {

        return ecgDao.getOne(id);
    }

    @Override
    public List<Ecg> getAll() {
        return ecgDao.getAll();
    }

    @Override
    public List<Ecg> getAllFromEcg8Hours() {
        return ecgDao.getAllFromEcg8Hours();
    }

    @Override
    public List<Ecg> getOnePageDate(Integer page) {
        List<Ecg> onePageDate = ecgDao.getOnePageDate(page);
        return onePageDate;
    }

    @Override
    public List<Ecg> getFWave() {
        return ecgDao.getFWave();
    }

    @Override
    public List<Ecg> getMix() {
        return ecgDao.getMix();
    }

    @Override
    public List<Ecg> getEcg() {
        return ecgDao.getEcg();
    }

}
